package com.ysd.lis.controller.emr;


import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.dto.emr.EmrDto;
import com.ysd.lis.entity.emr.EmrItemStandard;
import com.ysd.lis.request.emr.EmrParam;
import com.ysd.lis.service.emr.EmrItemStandardService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * cold_chain.sys_module 前端控制器
 * </p>
 *
 * @author prs
 * @since 2024-12-18
 */
@Api(tags = "标准模型")
@RestController
@RequestMapping("/lis/emr/itemStandard")
public class EmrItemStandardController extends BaseController {

    @Autowired
    EmrItemStandardService emrItemStandardService;

    @ApiOperation("获取菜单树")
    @GetMapping("/findEmrItemStandardList")
    public Result findEmrItemStandardList(EmrParam emrParam){
        return emrItemStandardService.findEmrItemStandardList(emrParam);
    }

    @ApiOperation("新增")
    @PostMapping("/addItemStandard")
    public Result addItemStandard(@RequestBody EmrItemStandard emrItemStandard){
        return  emrItemStandardService.addItemStandard(emrItemStandard);
    }

    @ApiOperation("修改")
    @PostMapping("/editItemStandard")
    public Result editItemStandard(@RequestBody EmrItemStandard supplier) {
        return emrItemStandardService.editItemStandard(supplier);
    }

    @ApiOperation("批量删除")
    @PostMapping("/batchDeleteItemStandard")
    public Result batchDeleteItemStandard(@RequestBody EmrDto dto){
        return  emrItemStandardService.batchDeleteItemStandard(dto);
    }

}
